package com.xdxc.model.entity;


import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.xdxc.utils.JsonTypeHandler;
import com.xdxc.utils.ListStringJsonTypeHandler;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.List;

@Data
@Builder
@Schema(description = "系统用户实体类")

@TableName(value = "sys_user", autoResultMap = true)
@NoArgsConstructor
@AllArgsConstructor
public class SysUser implements Serializable {

    private  Long id;
    private String userName;
    private String password;

    private String name;

    private String phone;

    private String avatar;

    private String description;

    private Integer status;

    private String salt;

    @TableField(value = "roles",typeHandler = JsonTypeHandler.class)
    private List<String> roles;




}